<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>大写锁定提示</title>
</head>
<body>
    <!-- 需要优化开屏显示 -->
    <div>
        
        <input @keydown.20="capslock = !capslock">
        <p v-show="capslock">当前已切换大写模式！</p>
        

    </div>

    <script>
        export default {
          name: "Class02",
          data() {
            return {
              
              capslock: false
            }
          },
        }
        </script>
</body>
</html>